/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package ejb;

import entity.Invitation;
import java.util.List;
import javax.ejb.Stateless;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;

/**
 *
 * @author user
 */

@Stateless
public class Invitationejb {
    
    @PersistenceContext(unitName = "meteocalpersist")
    EntityManager eminvitation;
    
    public void persistInvitation(List<Invitation> invitationlist){
        for(int i=0; i< invitationlist.size(); i++){
            eminvitation.persist(invitationlist.get(i));
            
        }
    }
    
}
